import Layout from '@/layout'
import RouteButtonsBuilder from '@/framework/infra/router/RouterButtonsBuilder'

export default [{
  path: '/system',
  component: Layout,
  name: 'system',
  meta: { title: '系统', icon: 'el-icon-s-tools' },
  children: [
    {
      path: 'manager',
      name: 'system-manager',
      component: () => import('@/feature/system/app/manager/index'),
      meta: { title: '运营人员', icon: 'el-icon-setting' },
      buttons: RouteButtonsBuilder.builder('admin').curdoo({ batchOO: false })
        .reLabel({ 'online': '启用', 'offline': '停用' })
        .addButton({ name: 'reset', label: '重置密码' })
        .build()
    },
    {
      path: 'role',
      name: 'system-role',
      component: () => import('@/feature/system/app/role/index'),
      meta: { title: '角色管理', icon: 'el-icon-setting' },
      buttons: RouteButtonsBuilder.builder('role').curd().addButton({
        name: 'power',
        label: '权限'
      }).build()
    }
    // {
    //   path: 'banner',
    //   name: 'system-banner',
    //   component: () => import('@/feature/system/app/banner'),
    //   meta: { title: 'banner广告', icon: 'el-icon-setting' },
    //   buttons: RouteButtonsBuilder.builder('banner').curdoo().build()
    // }
    // {
    //   path: 'sys-info',
    //   name: 'system-sys-info',
    //   component: () => import('@/feature/system/app/sys-info/index'),
    //   meta: { title: '页面管理', icon: 'el-icon-setting' },
    //   buttons: RouteButtonsBuilder.builder('system-sys-info').r().e()
    //     .build()
    // }
    // #appendSpot# 生成工具用，不要删了
  ]
}]

